// LessonInformationset.cpp : implementation file
//

#include "stdafx.h"
#include "SelectLesson.h"
#include "LessonInformationset.h"

#ifdef _DEBUG
#define new DEBUG_NEW
#undef THIS_FILE
static char THIS_FILE[] = __FILE__;
#endif

/////////////////////////////////////////////////////////////////////////////
// CLessonInformationset

IMPLEMENT_DYNAMIC(CLessonInformationset, CRecordset)

CLessonInformationset::CLessonInformationset(CDatabase* pdb)
	: CRecordset(pdb)
{
	//{{AFX_FIELD_INIT(CLessonInformationset)
	m_LessonNumber = 0;
	m_LessonName = _T("");
	m_TeacherNumber = 0;
	m_MaxNumber = 0;
	m_nFields = 5;
	//}}AFX_FIELD_INIT
	m_nDefaultType = dynaset;
}


CString CLessonInformationset::GetDefaultConnect()
{
	return _T("ODBC;DSN=");
}

CString CLessonInformationset::GetDefaultSQL()
{
	return _T("[LessonInformation]");
}

void CLessonInformationset::DoFieldExchange(CFieldExchange* pFX)
{
	//{{AFX_FIELD_MAP(CLessonInformationset)
	pFX->SetFieldType(CFieldExchange::outputColumn);
	RFX_Int(pFX, _T("[LessonNumber]"), m_LessonNumber);
	RFX_Text(pFX, _T("[LessonName]"), m_LessonName);
	RFX_Int(pFX, _T("[TeacherNumber]"), m_TeacherNumber);
	RFX_Date(pFX, _T("[BeginDate]"), m_BeginDate);
	RFX_Int(pFX, _T("[MaxNumber]"), m_MaxNumber);
	//}}AFX_FIELD_MAP
}

/////////////////////////////////////////////////////////////////////////////
// CLessonInformationset diagnostics

#ifdef _DEBUG
void CLessonInformationset::AssertValid() const
{
	CRecordset::AssertValid();
}

void CLessonInformationset::Dump(CDumpContext& dc) const
{
	CRecordset::Dump(dc);
}
#endif //_DEBUG
